package com.toommi.refuse.service;

import com.github.pagehelper.PageInfo;
import com.toommi.refuse.exception.AppUserException;
import com.toommi.refuse.model.AppLoginModel;
import com.toommi.refuse.model.AppUserModel;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * ..
 * APP端用户服务
 *
 * @author yangg
 * @since 2019-07-23 16:05
 */
public interface AppUserService {

    /**
     * 获取用户列表
     *
     * @param pageSize    每页数据量
     * @param currentPage 当前页码
     * @param keyWord     关键字
     * @return 用户列表
     */
    PageInfo<AppUserModel> getUsers(int pageSize, int currentPage, String keyWord);

    /**
     * 新增用户
     *
     * @param appUserModel 用户信息
     * @throws AppUserException 用户信息校验异常
     */
    void saveUser(AppUserModel appUserModel) throws AppUserException;

    /**
     * 修改用户信息
     * @param appUserModel 用户信息
     */
    void updateUser(AppUserModel appUserModel) throws AppUserException;

    /**
     * 删除用户信息
     * @param id 用户信息
     */
    void deleteUser(long id) throws AppUserException;
    /**
     * 登录
     * @param appUserModel 用户登录对象
     * @return 登录身份标识token
     */
    AppLoginModel login(AppUserModel appUserModel) throws AppUserException;

    /**
     * 获取小区列表
     * @param name
     * @return
     */
    Object getxqlist(String name,int pageSize, int pageNum)throws AppUserException;

    String push_Message(HttpServletRequest request, HttpServletResponse response);

    Object CommonResponse(HttpServletRequest request)throws AppUserException;

    Object hssq(HttpServletRequest request)throws AppUserException;
}
